import React, { memo } from 'react'

export default memo(
    function TdItem(props) {
        const { id, completed, content, completedChange, removeItem } = props
        return (
            <li>  <input type="checkbox" onChange={() => completedChange(id)} defaultChecked={completed} />
                <span>{content}</span>
                <button onClick={() => removeItem(id)}>删除</button> </li>
        )
    }

)